﻿Namespace Negocios

    Public Class Apoio

#Region "Propriedades"

        Public Shared ReadOnly Property ChaveCriptografia As String
            Get
                Return Convert.ToString(My.Resources.ChaveCriptografia)
            End Get
        End Property

        'Friend Shared ReadOnly Property ConnectionString As String
        '    Get
        '        Return System.Web.Configuration.WebConfigurationManager.ConnectionStrings("AESP").ToString
        '    End Get
        'End Property

        Public Shared ReadOnly Property SituacaoAtivo As Integer
            Get
                Return Convert.ToInt32(My.Resources.SituacaoAtivo)
            End Get
        End Property

        Public Shared ReadOnly Property SituacaoInativo As Integer
            Get
                Return Convert.ToInt32(My.Resources.SituacaoInativo)
            End Get
        End Property


#End Region

#Region "Funções Privadas"


#End Region

#Region "Funções Publicas"

        Public Shared Function Criptografa(ByVal strDado As String) As String

            Dim objFFuncoees As New FBiblioteca.Funcoes

            Return objFFuncoees.Criptografa(strDado, ChaveCriptografia, FBiblioteca.Funcoes.TipoCriptografia.Base64)

        End Function

        Public Shared Function Descriptograda(ByVal strDado As String) As String

            Dim objFFuncoes As New FBiblioteca.Funcoes

            Return Convert.ToString(objFFuncoes.Descriptografa(strDado, ChaveCriptografia, FBiblioteca.Funcoes.TipoCriptografia.Base64))

        End Function

#End Region

    End Class

End Namespace

